import  Request  from '../utlis/axios'

// 登录接口
export const login = (data)=> Request({
    url:'/login',method:'post',data,
})
// 左侧菜单栏接口
export const menu = ()=> Request({
    url:'/menus',method:'get',
})
//退出没接口
// 用户列表
// 获取用户数据
export const user = (url) => Request({
    url,
})
// 删除用户
export const user_del = (url,method) => Request({
    url,method
})
// 添加用户
export const user_add = (data) => Request({
    url:'/users/',method:'post',data,
})
// 设置用户状态
export const user_status = (url) => Request({
    url,method:'put',
})
// 修改用户
export const user_edit = (url,data) => Request({
    url,method:'put',data,
})
// 获取分配角色列表
export const user_rightInfo = () => Request({
    url:"/roles",
})
// 设置角色
export const user_rightEdit = (url,data) => Request({
    url,method:'put',data
})
// 权限列表
// 权限
export const rights = (url) => Request({
    url,
})
// 权限角色
export const ruser = (url) => Request({
    url,
})
// 权限角色添加
export const ruser_add = (data) => Request({
    url:'roles/',method:'post',data
})
// 权限角色删除
export const ruser_del = (url) => Request({
    url,method:'delete',
})
// 权限角色修改前
export const ruser_beforeEdit = (url) => Request({
    url,
})
// 权限角色修改后
export const ruser_Edit = (url,data) => Request({
    url,data,method:'put'
})
// 权限删除
export const ruser_Del = (url) => Request({
    url,method:'delete'
})
// 权限角色权限
export const ruser_beforeright = (url) => Request({
    url,
})
// 权限角色权限修改
export const ruser_righted = (url,data) => Request({
    url,method:'post',data
})
// 订单页
export const oder = (url) => Request({
    url,
})
// 快递
export const oder_address = (url) => Request({
    url,
})
// 修改状态
export const oder_editStatus = (url) => Request({
    url,method:'put'
})
// 查看
export const oder_searchStatus = (url) => Request({
    url
})